<?php
	include "../common/db.inc";
	$mysqli = new mysqli($host, $username, $password,$dbname);
	$mysqli->set_charset('utf8');
	if (mysqli_connect_errno()) {
	    printf("Connect failed: %s\n", mysqli_connect_error());
	    exit();
	}
	$userId = $mysqli->real_escape_string($_GET['u']);
	$ebookId = $mysqli->real_escape_string($_GET['e']);
	$query = ("call sp_AddNeededList('$userId', '$ebookId')");
	@$mysqli->query($query);
	$mysqli->close();
		
	echo "<input type='button' disabled='disabled' value='Thêm vào danh sách' title='Thêm vào danh sách cần download'></input>";
?>
